package com.yungui.rabbitmq.controller;

import com.yungui.rabbitmq.mq.rocket.RocketMqService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {

    @Autowired
    private RocketMqService rocketMqService;


    @RequestMapping(value = "/push/message", method = {RequestMethod.GET})
    public String testStringQueue(String msg) {
        // 可以不使用Config中的Group
        rocketMqService.pushMessage(msg);
        return "ok";
    }
}